package main.java.com.extract;

/**
 * @description: java类作用描述
 * @author: cong zhi
 * @createDate: 2022/6/16 17:50
 * @updateUser: cong zhi
 * @updateDate: 2022/6/16 17:50
 * @updateRemark: 修改内容
 * @version: v1.0
 */
public class HtmlStatement extends Statement {

    @Override
    public String headerString(Customer customer) {
        return "<H1>Rentals for <EM>" + customer.getName() + "</EM></H1></P>\n";
    }

    @Override
    String eachRentalString(Rental rental) {
        return "\t" + (rental.getMovie().getTitle() + ":" + rental.getAmount() + "<BR>\n");
    }

    @Override
    String footerString(Customer customer) {
        return "<P>You owe<EM>" + customer.getTotalAmount() + "</EM><P>" + "On this rental you earned <EM>"
                + customer.getTotalfrequentRenterPoints() + "</EM> frequent renter points<P>";
    }


}
